__author__ = 'nvsmirnov'
# -*- coding: utf-8 -*-
import unittest
from Framework.DataClasses.CUser import *
from Framework.PageClasses.CpLogin import CpLogin
from Framework.PageClasses.CpDefault import CpDefault
from Tests._tcBase import _tcBase
from Framework.PageClasses.CpEditProviderProfile import CpEditProviderProfile

class EditProvider(unittest.TestCase, _tcBase):
    def setUp(self):
        _tcBase.setUpFireFox(self)

    def tearDown(self):
        _tcBase.tearDown(self)
        #_tcBase.clear_ie_cache(self)

    def test_Edit(self):
        pageLogin = CpLogin(self.driver)
        pageLogin.open(self.driver, pageLogin.url)

        pageLogin.loginAs(user3)

        pageEdit = CpEditProviderProfile(self.driver)
        pageEdit.openProfile()
        pageEdit.enterProfile()

        pageEdit.fillForm()
        pageEdit.fillDocuments()

        pageEdit.submit()

        pageDefault = CpDefault(self.driver)
        pageDefault.LogOut()

if __name__ == '__main__':
    unittest.main()
